<!DOCTYPE HTML>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>信息操作页面</title>
<link type="text/css" media="screen" charset="utf-8" rel="stylesheet" href="template/default/content/css/style.account-1.1.css" />
<link charset="utf-8" rel="stylesheet" href="template/default/content/css/personal.record-1.0.css" media="all" />
<link rel="stylesheet" type="text/css" href="template/default/content/css/style.css">
<style type="text/css"> 
.tip-faq{
	clear:both;
	margin-top:0px;
}
#J-table-consume{
	margin-bottom:40px;
}
.ui-form-tips .m-cue{
	 background-position: -27px -506px;
	 *background-position: -27px -505px;
}
#J-set-date a{
	font-family:宋体;
}
</style>
<script type="text/javascript" charset="utf-8" src="template/default/content/js/arale.js"></script>
<script charset="utf-8" src="template/default/content/js/recordIndex.js?t=20110523"></script>
<script language="javascript" type="text/javascript" src="template/default/js/jquery.min.js"></script>
<script language="javascript" type="text/javascript" src="template/default/content/js/common.js"></script>
<script language="javascript" type="text/javascript" src="DatePicker/WdatePicker.js"></script>
<script type="text/javascript"> 
E.onDOMReady(function() {

	record = new AP.widget.Record({
		dom: {
			queryForm : "queryForm",
			searchForm : "topSearchForm",
			keyword : "J-keyword",
			keywordType : "J-keyword-type"
		}
	});

	//切换高级筛选状态
	E.on('J-filter-link', 'click', record.switchFilter);
});
function show_help()
{
   mytop=(screen.availHeight-430)/2;
   myleft=(screen.availWidth-800)/2;
   window.open("admin.php?ac=view&fileurl=help&helpid=<?=$ac?>","","height=470,width=800,status=0,toolbar=no,menubar=no,location=no,scrollbars=yes,top="+mytop+",left="+myleft+",resizable=yes");
}
</script>
</head>
<!--[if lt IE 7]><body class="ie6"><![endif]--><!--[if IE 7]><body class="ie7"><![endif]--><!--[if IE 8]><body class="ie8"><![endif]--><!--[if !IE]><!--><body><!--<![endif]-->
<div id="container" class="ui-container">
 
<div id="content" class="ui-content fn-clear" coor="default" coor-rate="0.02">
	<div class="ui-grid-21" coor="content">
<table width="90%" border="0" align="center" cellpadding="3" cellspacing="0" class="small">
  <tr>
    <td class="Big"><img src="template/default/content/images/notify_new.gif" align="absmiddle"><span class="big3">在线考勤</span>&nbsp;&nbsp;&nbsp;&nbsp;
	<span style="font-size:12px;"><a href="#" onClick="show_help()" style="font-size:12px;">使用帮助文档？</a>&nbsp;|&nbsp;
	<a href="http://bbs.515158.com/" target="_blank" style="font-size:12px;">使用遇到问题？</a></span>
    </td>
  </tr>
</table>
<script Language="JavaScript"> 
function CheckForm()
{
   if(document.save.id.value=="")
   { alert("id不能为空！");
     document.save.id.focus();
     return (false);
   }
   return true;
}
function sendForm()
{
   if(CheckForm())
      document.save.submit();
}
</script>	
<form name="save" method="post" action="?ac=<?=$ac?>&fileurl=<?=$fileurl?>&do=add">
	<input type="hidden" name="id" value="<?=$rowdata['id']?>" />
	 <table class="TableBlock" border="0" width="90%" align="center" style="border-bottom:#4686c6 solid 0px;">
	 
    
	
		<tr>
			<td nowrap class="TableHeader" colspan="4"><b>&nbsp;上班打卡</b> </td> 	  	
		</tr>
	
		<tr>
      <td nowrap class="TableContent" width="15%"> 打卡时间：</td>
      <td class="TableData"><?=$rowdata['startdate']?></td>
      <td class="TableContent" width="15%">签到状态</td>
      <td class="TableData">
	  <? if($rowdata['startyype']=='0'){?>
	  正常上班
	  <? }else{?>
	  迟到
	  <? }?>	  </td>
    </tr>
	<? if($rowdata['startyype']=='1'){?>
	<tr>
			<td nowrap class="TableContent" width="15%">迟到原因：<? get_user_add_help()?></td>
			  <td colspan="3" class="TableData">
			  <input type="text" name="startnote" class="BigInput" size="60" value="<?=$rowdata['startnote']?>" />				</td>
		  </tr>
	<? }?>

	<? if(get_date('H',PHP_TIME)>12){?>	
	
		<tr>
			<td nowrap class="TableHeader" colspan="4"><b>&nbsp;下班打卡</b> </td> 	  	
		</tr>
	
		<tr>
      <td nowrap class="TableContent" width="15%"> 打卡时间：</td>
      <td class="TableData"><?=$rowdata['enddate']?></td>
      <td class="TableContent" width="15%">签到状态</td>
      <td class="TableData">
	  <? if($rowdata['endtype']=='0'){?>
	  正常下班
	  <? }else{?>
	  早退
	  <? }?>	  </td>
    </tr>
	<? if($rowdata['endtype']=='1'){?>
	<tr>
			<td nowrap class="TableContent" width="15%">早退原因：<? get_user_add_help()?></td>
			  <td colspan="3" class="TableData">
			  <input type="text" name="endnote" class="BigInput" size="60" value="<?=$rowdata['endnote']?>" />				</td>
		  </tr>
	<? } }?>
	
		
		<tr align="center" class="TableControl">
			<td colspan="4" nowrap>
			<? if($rowdata['endtype']=='1' || $rowdata['startyype']=='1'){?>
			<input type="button" value="保存" class="BigButtonBHover" onClick="sendForm();">
			<? }?>
			</td>
	  </tr>
	 </table>
  
</form>
 

		<div class="ui-grid-21 ui-grid-right fn-clear" coor="total">
		                                <table width="100%" border="0" align="center" cellpadding="0" cellspacing="0">
                                          <tr>
                                            <td width="91%">
											<?=showpage($num,$pagesize,$page,$url)?></td>
                                            <td width="9%" align="right" style="padding-right:10px;"></td>
                                          </tr>
                                        </table>
		  
										

	  </div>
	</div>
	<form name="update" method="post" action="admin.php?ac=<?=$ac?>&fileurl=<?=$fileurl?>">
		<input type="hidden" name="do" value="update" />
		<div class="ui-grid-21 ui-grid-right fn-clear" id="J-table-consume" coor="consumelist">
			<div class="ui-tab">
												<div class="ui-tab-trigger"> 
					<ul class="fn-clear"> 
<li class="ui-tab-trigger-item<?=$_check['ischeck']?>">
<a href="admin.php?ac=<?=$ac?>&fileurl=<?=$fileurl?>" class="ui-tab-trigger-text">历史考勤记录</a></li>						
</ul>
				</div>
 
				<div class="ui-tab-container" id="myScene">
					<div class="ui-tab-container-item ui-tab-container-item-current">
					
					

					
						<table id="tradeRecordsIndex" class="ui-table">

							<thead>
								<tr>
									<th class="checkbox">
									</th>
									<th class="info">日期</th>
									<th class="info">姓名</th>
									<th class="info">上班时间</th>
									<th class="info">下班时间</th>
									<th class="info">迟到/早退原因</th>
									<th class="info">迟到/早退状态</th>
								</tr>
							</thead>
							
							
							
							
							<tbody>
<?foreach ($result as $row) {?>
																																								
<tr <?php if($result%2==0){?>class="split" <?php }?>>
<td class="checkbox">
<?=get_checkbox_list_key("id[]",$row['id'],$row['uid'],$_USER->id)?></td>
<td class="info"><?=$row['date']?></td>
<td class="info">
<?=$row['name']?>
</td>
<td class="info">
<?=str_replace(" ","<br>",$row['startdate'])?>
</td>
<td class="info">
<?=str_replace(" ","<br>",$row['enddate'])?>
</td>
<td class="info">
<?=$row['startnote']?><br><?=$row['endnote']?>
</td>
<td class="info">
<? if($rowdata['startyype']=='0'){?>
	  正常上班
	  <? }else{?>
	  迟到
	  <? }?>
/
<? if($rowdata['endtype']=='0'){?>
	  正常下班
	  <? }else{?>
	  早退
	  <? }?>
</td>
									
</tr>
<?}?>			
																									
</tbody>
		</table>
 
											</div>
					
					<div class="fn-clear">
						<!-- 图释 -->
					  <div class="iconTip fn-left">
						
</div>
						
												<div class="page page-nobg fn-right">
							<span class="page-link"><?=showpage($num,$pagesize,$page,$url)?></span>
						</div>
						<!-- /分页 -->
											</div>
				</div>
			</div>
 
		
		</div>
		<!-- /交易记录-->
 </form>		
	</div>
 
 
	
</div>


</div>

                            

</body>
</html>
 

